package com.home.duy.code.components;

import java.awt.GridBagLayout;

import javax.swing.ImageIcon;
import javax.swing.JButton;
import javax.swing.JPanel;
import javax.swing.JLabel;

import com.home.Common.Common;
import com.home.Common.Resources_Duy;

import java.awt.Graphics;
import java.awt.Graphics2D;
import java.awt.Rectangle;
import java.awt.Dimension;

public class PanelDisplayBan extends JPanel {

	private static final long serialVersionUID = 1L;
	private JLabel lblTenBan = null;
	private JLabel lblHinhBan = null;

	/**
	 * This is the default constructor
	 */
	public PanelDisplayBan() {
		super();
		initialize();
	}
	
	public void setTenBan(String tenBan)
	{
		lblTenBan.setText(tenBan);
	}
	
	public void setHinhBan(ImageIcon imgBan)
	{
		lblHinhBan.setIcon(imgBan);
	}
	
	@Override
	public void paint(Graphics g) {
		super.paint(g);
	}
	@Override
	public void paintComponents(Graphics g) {
		super.paintComponents(g);
		
	}
	
	/**
	 * This method initializes this
	 * 
	 * @return void
	 */
	private void initialize() {
		lblHinhBan = new JLabel();
		lblHinhBan.setBounds(new Rectangle(11, 26, 128, 128));
		lblHinhBan.setText("");
		lblHinhBan.setIcon(Common.getImageIcon(Resources_Duy.IMAGE_DEFAULT_BAN));
		lblTenBan = new JLabel();
		lblTenBan.setBounds(new Rectangle(0, 0, 152, 25));
		lblTenBan.setText("aaa");
		this.setSize(153, 155);
		this.setLayout(null);
		this.add(lblTenBan, null);
		this.add(lblHinhBan, null);
	}

}  //  @jve:decl-index=0:visual-constraint="10,10"
